package com.example.tokentest2_7_x.redispackage;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

/**
 * \* @author: wky
 * \* Date: 2022/10/08
 * \* Time: 18:19
 * \* To change this template use File | Settings | File Templates.
 * \* Description:RedisTest
 * \
 */
@Component
public class RedisTest {

    @Autowired
    RedisCache redisCache;

    @PostConstruct
    private void init() {
        test();
    }

    private  void test() {
        /*redisCache.setCacheObject("token", "12345678901234567890",10, TimeUnit.MINUTES);
        String str = redisCache.getCacheObject("token");
        System.out.println(str);*/
    }

}